<?PHP
error_reporting(E_ALL ^ E_NOTICE);

require_once('utils.php');
require_once('Security.php');
require_once('core.php');

require_once('LoginForm.php');
require_once('MainForm.php');

function Main()
{
	switch ( utils::CurrentPage() )
	{
		case '/login':
			$currentForm = new LoginForm();
			break;
		case '/main':
			$currentForm = new MainForm();
			break;
		default:
			utils::Redirect(utils::AppLocation() . '/main');
			break;
	}

	Application::Run($currentForm);
}

Main();
?>
